<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>

<link rel="stylesheet" href="${basePath}/static/plugins/datepicker/bootstrap-datetimepicker.css">
<link rel="stylesheet" href="${basePath}/static/plugins/datatables/dataTables.bootstrap.css">

<section class="content-header">
	<ol class="breadcrumb">
		<li><a href="${basePath }/daily/dailyView"><i
				class="fa fa-dashboard"></i> 积分管理</a></li>
		<li class="active">积分规则明细</li>
	</ol>
</section>
<div class="content">
	<div class="panel panel-info">
		<div class="panel-heading">积分规则明细</div>
		<div class="panel-body">
			<!-- 查询列表  start-->
			<form id="ruleDetailSearchForm">
				<div class="row" role="form">
					<div class="form-group form-inline col-sm-3">
						<label for="ruleDetailName">名称:</label> 
						<input type="text" class="form-control" name="ruleDetailName" id="ruleDetailName"
							style="width: 160px;" placeholder="执行频率名称">
					</div>
					<div class="form-group form-inline col-sm-3">
						<label for="cycle">周期:</label>
						<select class="form-control" name="cycle" style="width: 160px;">
							<option value="">---请选择---</option>
							<c:forEach items="${cycles}" var="cycle">
								<option value="${cycle.val}">${cycle.name}</option>
							</c:forEach>
						</select> 
					</div>
					<div class="form-group form-inline col-sm-3">
						<label for="times">次数:</label>
						<select class="form-control" name="times" style="width: 160px;">
							<option value="">---请选择---</option>
							<c:forEach items="${executionTimes}" var="time">
								<option value="${time.val}">${time.name}</option>
							</c:forEach>
						</select> 
					</div>
					<!--
				  	<div class="col-sm-1">
				  		<a class="more-ops ex-options">更多选项</a>
				  		<a class="more-ops cl-options" style="display:none;">收起选项</a>
				  	</div>
				  	 -->
					<div class="col-sm-2">
						<button type="button" class="btn btn-info" style="width: 120px;" id="ruleDetailSearch">查 询</button>
					</div>
				</div>
				<div class="row" role="form" id="extendCondition"
					style="display: none;"></div>
			</form>
			<!-- 查询列表  end -->
			<br>
			<div class="toolBar" style="margin: 5px;">
				<button type="button" id="ruleDetailAdd" class="btn btn-success btn-xs"
					style="width: 80px;">新&nbsp;&nbsp;增</button>
				<button type="button" id="ruleDetailDel" class="btn btn-danger btn-xs"
					style="width: 80px;">删&nbsp;&nbsp;除</button>
			</div>
			<!-- 规则执行频率表格内容 start-->
			<table id="rule_detail_grid" class="table table-bordered table-hover">
				<thead>
					<tr>
                        <th><input type="checkbox" name="checkAll" id="ruleCheckAll"></th>
						<th>序号</th>
						<th>名称</th>
						<th>频率</th>
						<th>次数</th>
						<th>是否有效</th>
                        <th>操作</th>
					</tr>
				</thead>
			</table>
			<!-- 规则执行频率表格内容 end -->
		</div>
	</div>
</div>

<!-- 规则执行频率新增用模态框 -->
<div class="modal fade" id="rule_detail_add_modal" tabindex="-1" role="dialog">
	<form id="rule_detail_add_from">
		<div class="modal-dialog">
			<div class="modal-content">
				<div class="modal-body no-padding">
					<div class="box box-primary">
						<div class="box-header with-border">
							<h3 class="box-title">新增规则执行频率</h3>
						</div>

						<div class="box-body"></div>
					</div>
				</div>
				<div class="modal-footer">
					<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
					<button type="submit" class="btn btn-primary">保存</button>
				</div>
			</div>
		</div>
	</form>
</div>

<!-- 规则执行频率更新用模态框 -->
<div class="modal fade" id="rule_detail_update_modal" tabindex="-1" role="dialog">
	<form id="rule_detail_update_form">
		<div class="modal-dialog">
			<div class="modal-content">
				<div class="modal-body no-padding">
					<div class="box box-primary">
						<div class="box-header with-border">
							<h3 class="box-title">修改规则执行频率</h3>
						</div>

						<div class="box-body"></div>
					</div>
				</div>
				<div class="modal-footer">
					<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
					<button type="submit" class="btn btn-primary">保存</button>
				</div>
			</div>
		</div>
	</form>
</div>

<script src="${basePath}/static/plugins/datepicker/bootstrap-datetimepicker.js"></script>
<script src="${basePath}/static/plugins/datepicker/locales/bootstrap-datetimepicker.zh-CN.js"></script>
<script src="${basePath}/static/plugins/datatables/jquery.dataTables.js"></script>
<script src="${basePath}/static/plugins/datatables/dataTables.bootstrap.js"></script>
<script type="text/javascript" src="${basePath}/static/plugins/jquery.validate/jquery.validate.min.js"></script>

<script src="${basePath}/static/adminLTE/js/integral/rule-detail.js"></script>

